#!/usr/bin/env python
# -*- coding:utf-8 -*-
# Author:Taotie Ren

username = input("user:")
if username.strip('') == 'ttr':
    #strip  默认移除空白
    print("welcome")

names = "jack,rain,tom"
name2 = names.split(",")
print(name2)
print("|".join(name2))

name3 = "Tom Jarry"
print(name3.capitalize())

msg = "Hello, {name4},It's been a long {age} sence last time sopke"
msg2 = msg.format(name4 = "tom",age = 233)
print(msg2)

msg3 = "haaaaa{0},emmmm{1}"
print(msg3.format("Tom",23))

print(name3.center(40,"*"))

age1 =input("Your age:")
if age1.isdigit():
    age = int (age1)
else:
    print("invalid data type")

job = "adfhkljl1234568709djakl"
print(job.isalnum())
print(job.endswith('akl'))
print(job.startswith("adf"))
print(job.upper())
print(job.lower())